package designpattern.observer;

import java.util.Observable;
import java.util.Observer;

/**
 * 警告监听
 * @author liuboen
 * 
 * since:2012-6-7
 * version:1.0.0
 */
public class Alarm implements Observer {

	@Override
    public void update(Observable arg0, Object arg1) {
       this.makeAlarm((Integer) arg1);
    }
 
    private void makeAlarm(int temperature) {
       System.out.println("这是一个警告");
    }

}
